package b4.view.component.load
{
	import b4.view.component.basic.BasicWidget;
	import b4.view.component.basic.MaskProgressBar;
	
	import flash.events.*;
	import flash.filters.*;
	import flash.text.*;

	public class LoadScene extends BasicWidget
	{
		public var loadBar:MaskProgressBar;
		public var loadText:TextField;
		
		public function LoadScene()
		{
			addChild(new MainLoadBgr());
			//LOGO
			var logoSprite:BasicWidget = new BasicWidget();
			logoSprite.anchor = BasicWidget.ANCHOR_MIDDLE_MIDDLE;
			logoSprite.addChild(new MainLogo());
			logoSprite.x = -logoSprite.width / 2;
			logoSprite.y = -150;
			addChild(logoSprite);
			//进度条
			loadBar = new MaskProgressBar(MainProcessBar, MainProcessBarBgr);
			loadBar.x = (this.width - loadBar.width) / 2;
			loadBar.y = 400;
			addChild(loadBar);
			//文字
			loadText = new TextField();
        	loadText.autoSize = TextFieldAutoSize.CENTER;
			loadText.defaultTextFormat = new TextFormat("微软雅黑", 16, 0xFFFFFF);
			loadText.filters = [new GlowFilter(0x000000, 1, 1.3, 1.3, 100, BitmapFilterQuality.HIGH)];
			loadText.selectable = false;
			loadText.x = this.width / 2;
			loadText.y = 350;
			addChild(loadText);
		}
	}
}